<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        /* 浏览器解析行内块或者行内标签的时候。如果标签换行书写会产生一个空格的距离 */
        /* 使用浮动float可以解决上述问题 */
        /* div {
        li:nth-child(2n)
            display: inline-block;
            width: 100px;
            height: 100px;
        } */
        /* 浮动的特点：当设置浮动后，浮动元素会脱离标准流 */
        .one {
            width: 100px;
            height: 100px;
            background-color: pink;

            float: left;
        }
        .two {
            width: 200px;
            height: 200px;
            background-color: skyblue;

            /* 浮动生效后，盒子无法生效 */
            /* margin:0 auto; */
            float:left;
        }
        .three {
            width: 300px;
            height: 300px;
            background-color: orange;

            /* float:left; */
        }
    </style>
</head>
<body>
    <div class="one">one</div>
    <div class="two">two</div>
    <div class="three">three</div>
</body>
</html>